package com.zzl.bonds.ticket.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.zzl.apidoc.annotation.ApidocModel;
import com.zzl.apidoc.annotation.ApidocModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 票的操作记录表
 *
 * @author gull
 * @date 2022-07-06 13:43:53
 */
@Data
@TableName("t_ticket_operate_log")
@ApidocModel
@SuppressWarnings("javadoc")
public class TicketOperateLogEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.UUID)
    @ApidocModelProperty(description = "主键")
    private String id;
    @ApidocModelProperty(description = "凭证申请的id")
    private String applyId;
    @ApidocModelProperty(description = "1，开立申请 2，转让申请，3，融资申请")
    private String applyType;
    @ApidocModelProperty(description = "凭证上一个状态")
    private String ticketPreviousStatus;
    @ApidocModelProperty(description = "操作类型 1、开单申请 2、复核通过 3、审批通过 4、签收 5、拆转申请 6、融资申请 等")
    private String operateType;
    @ApidocModelProperty(description = "凭证状态")
    private String ticketStatus;
    @ApidocModelProperty(description = "操作人id")
    private String operateId;
    @ApidocModelProperty(description = "操作人")
    private String operateUser;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "操作时间", validate = "yyyy-MM-dd HH:mm:ss")
    private Date operateTime;
    @ApidocModelProperty(description = "发起方企业id")
    private String enterpriseId;
    @ApidocModelProperty(description = "发起方企业id")
    private String enterpriseName;
    @ApidocModelProperty(description = "签收方企业id")
    private String signEnterpriseId;
    @ApidocModelProperty(description = "签收方企业名称")
    private String signEnterpriseName;
    @ApidocModelProperty(description = "融资的金融机构id")
    private String instinctyId;
    @ApidocModelProperty(description = "融资的金融机构名称")
    private String instinctyName;
    @ApidocModelProperty(description = "部门id")
    private Integer orgId;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "创建时间", validate = "yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApidocModelProperty(description = "修改时间", validate = "yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;
    @ApidocModelProperty(description = "创建人")
    private String creatorId;
    @ApidocModelProperty(description = "修改人")
    private String updaterId;
    @ApidocModelProperty(description = "备注")
    private String remark;
    @ApidocModelProperty(description = "对应的票据id")
    private String ticketId;

    @ApidocModelProperty(description = "审批结果，0 驳回 1 通过")
    private String approvalResult;

    @ApidocModelProperty(description = "模板节点总数量")
    private Integer templateNodeCounts;

    @ApidocModelProperty(description = "当前节点等级")
    private Integer nodeLevels;


    @ApidocModelProperty(description = "是否属于开立转让融资申请详情页里的操作记录 0是 1否")
    private String  isToApplication;

    @TableField(exist = false)
    private String ticketPreviousStatusName;
    @ApidocModelProperty(description = "操作类型 1、开单申请 2、复核通过 3、审批通过 4、签收 5、拆转申请 6、融资申请 等")
    @TableField(exist = false)
    private String operateTypeName;
    @TableField(exist = false)
    @ApidocModelProperty(description = "票据状态")
    private String ticketStatusName;

}
